﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Admin.Master" AutoEventWireup="true"
	CodeBehind="BlackList.aspx.cs" Inherits="SBACN.WebSite.Admin.MemberService.BlackList" %>

<%@ Register Src="../../UC/Pager.ascx" TagName="Pager" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
	<script src="../../js/plugin/jquery.blockUI.js" type="text/javascript"></script>
	<script type="text/javascript">
		function UpLoadScore() {
			$jqy.blockUI({
				message: $jqy("#UploadScore"),
				css: {
					top: '30%',
					left: '35%',
					width: '300px',
					hight: '300px'
				}
			})
		}
		function CancelBtnClick() {
			$jqy.unblockUI();
		}
		function Check() {

			var file = $jqy("#<%= FileUploadScore.ClientID %>").val();
			if (file == "") {
				alert("请选择需要上传的文件！");
				return false;
			}
			var fileArr = file.split("\\");
			var fileTArr = fileArr[fileArr.length - 1].toLowerCase().split(".");
			var filetype = fileTArr[fileTArr.length - 1];
			if (filetype != "xls") {
				alert("上传文件必须为Excel文件(xls)！");
				return false;
			}

			document.getElementById('form1').appendChild(document.getElementById('UploadScore'));
			$jqy.unblockUI();
			$jqy.blockUI({
				message: '<h5>上传处理中，请稍等...</h5>'
			});
			return true;
		}
		function DeleteSubject(id) {
			if (confirm("确认删除吗？")) {
				document.getElementById("<%= hid_ID.ClientID%>").value = id;
				document.getElementById("<%= btn_Delete.ClientID%>").click();
			}
		}

		function RefreshNewsList() {
			if (document.getElementById("<%= btn_NewsRefresh.ClientID%>")) {
				document.getElementById("<%= btn_NewsRefresh.ClientID%>").click();
			}
		}

	</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
	<table width="100%" border="0" cellspacing="0" cellpadding="0" class="table-stroke2">
		<tr>
			<td width="10%" class="form-title2">
				姓名
			</td>
			<td width="15%" class="form-title2">
				身份证
			</td>
			<td width="60%" class="form-title2">
				原服务机构名称
			</td>
			<td width="15%" class="form-title2">
				操作
			</td>
		</tr>
		<asp:Repeater runat="server" ID="List">
			<ItemTemplate>
				<tr>
					<td class="form-body">
						<%# Eval("PersonName")%>
					</td>
					<td class="form-body">
						<%# Eval("IDCard")%>
					</td>
					<td class="form-body">
						<%# Eval("CompanyName")%>
					</td>
					<td class="form-body">
						<a target="_blank" href="BlackEdit.aspx?st=<%= SystemType %>&id=<%# Eval("ID") %>">编辑</a>&nbsp;&nbsp;<a
							href="javascript:void(0)" onclick="DeleteSubject(<%# Eval("ID") %>)">删除</a>
					</td>
				</tr>
			</ItemTemplate>
			<AlternatingItemTemplate>
				<tr>
					<td class="form-label">
						<%# Eval("PersonName")%>
					</td>
					<td class="form-label">
						<%# Eval("IDCard")%>
					</td>
					<td class="form-label">
						<%# Eval("CompanyName")%>
					</td>
					<td class="form-label">
						<a target="_blank" href="BlackEdit.aspx?st=<%= SystemType %>&id=<%# Eval("ID") %>">编辑</a>&nbsp;&nbsp;<a
							href="javascript:void(0)" onclick="DeleteSubject(<%# Eval("ID") %>)">删除</a>
					</td>
				</tr>
			</AlternatingItemTemplate>
		</asp:Repeater>
		<tr>
			<td colspan="4" class="form-body">
				<a target="_blank" href="BlackEdit.aspx?st=<%= SystemType %>">新增</a>&nbsp;&nbsp;
				<a href="javascript:void(0)" onclick="UpLoadScore();">上传</a>&nbsp;&nbsp;
				<a href="../../Template/审慎录用人员名单.xls">下载审慎录用人员模版</a>
			</td>
		</tr>
		<tr>
			<td colspan="4">
				<uc1:Pager ID="Pager1" runat="server" OnSelectedPageIndexChanged="BindSelectedPageIndexChanged"
					PageSize="15" />
			</td>
		</tr>
	</table>
	<div style="display: none;" id="UploadScore">
		<table>
			<tr>
				<td>
					<asp:FileUpload ID="FileUploadScore" runat="server" CssClass="inputfile" />
					<span><font color="#FF0000">请上传xls文件。</font></span>
				</td>
			</tr>
			<tr>
				<td>
					<asp:HiddenField ID="HidSubjectID" runat="server" Value="0" />
					<asp:Button ID="ScoreUpLoadSubbtn" runat="server" Text="上传" CssClass="btnsearch"
						OnClientClick="return Check();" OnClick="ScoreUpLoadSubbtn_Click" />
					<input type="button" id="CancelBtn" value="取消" class="btnsearch" onclick="CancelBtnClick()" />
				</td>
			</tr>
		</table>
	</div>
	<div style="display: none;">
		<asp:HiddenField ID="hid_ID" Value="" runat="server" />
		<asp:Button Text="删除" ID="btn_Delete" runat="server" OnClick="btn_Delete_Click" />
		<asp:Button Text="刷新" ID="btn_NewsRefresh" runat="server" OnClick="btn_NewsRefresh_Click" />
	</div>
</asp:Content>
